<template>
	<div>
		<span>显示ActionSheet</span>
		<input type="checkbox" v-model="isShow" />
		
		<button @click="btnClick">弹出alert</button>
		
		
		<actionsheet 
			v-model="isShow"
			show-cancel
			cancel-text="消失"
			:menus="arr"
			@on-click-menu-album="albumClick"
			@on-click-menu-camera="cameraClick"
		></actionsheet>
		
	</div>
</template>

<script>
	
	import {Actionsheet} from "vux";
	
	export default{
		components:{
			Actionsheet
		},
		data:function(){
			return {
				isShow:false,
				arr:[
					{
						label:"<marquee>从相册选择</marquee>",
						type:"warn",
						value:"album"
					},
					{
						label:"拍照",
						type:"primary",
						value:"camera"
					}
				]
			}
		},
		methods:{
			albumClick(){
				alert("相册选择");
			},
			cameraClick(){
				alert("拍照");
			},
			btnClick(){
				this.$vux.alert.show({
					title:"提示",
					content:"电量已不足10%"
				});
			}
		}
	}
</script>

<style>
</style>